home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
TPUG - Toronto PET Users Group
/
TPUG Users Group CD
/
TPUG Users Group CD.iso
/
C64
/
T-TPUG Old Monthly Disks
/
(c)t6.d64
/
list-me life.l
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2007-02-04
|
8KB
|
223 lines
1000 **********************************
1010 * *
1020 * L III FFFF EEEE *
1030 * L I F E *
1040 * L I FFF EEE *
1050 * L I F E *
1060 * LLLL III F EEEE *
1070 * *
1080 **********************************
1090 * A SIMULATION OF LIFE! *
1100 **********************************
1110 THE GAME OF LIFE WAS FIRST PRESENT
1120 ED BY JOHN CONWAY, A MATHEMATICIAN
1130 AT CAMBRIDGE UNIVERSITY, IN THE
1140 OCTOBER, 1970 ISSUE OF SCIENTIFIC
1150 AMERICAN. SOME OF THE FOLLOWING
1160 IS COPIED FROM THAT ARTICLE.
1170 * *
1180 THE BASIC IDEA IS TO START WITH A
1190 SMALL GROUP OF "CELLS" IN A SIMPLE
1200 PATTERN, AND THEN OBSERVE HOW THAT
1210 PATTERN CHANGES AS YOU APPLY THE
1220 GENETIC LAWS DEVELOPED BY CONWAY.
1230 THE RULES FOLLOW THREE DESIDERATA:
1240 A) THERE SHOULD BE NO INITIAL PAT-
1250 . TERN FOR WHICH THERE'S A SIMPLE
1260 . PROOF THAT THE POPULATION CAN
1270 . GROW WITHOUT LIMIT.
1280 B) THERE SHOULD BE INITIAL PATT-
1290 . ERNS THAT APPARENTLY DO GROW
1300 . WITHOUT LIMIT.
1310 C) THERE SHOULD BE SIMPLE INITIAL
1320 . PATTERNS WHICH GROW AND CHANGE
1330 . FOR A CONSIDERABLE PERIOD OF
1340 . TIME BEFORE COMING TO AN END
1350 . IN ONE OF 3 POSSIBLE WAYS:
1360 . 1) FADE AWAY FROM OVERCROWDING
1370 . OR FROM BECOMING TOO SPARSE;
1380 . 2) SETTLE INTO A STABLE CON-
1390 . FIGURATION;
1400 . 3) OR ENTER AN OSCILLATING
1410 . PHASE WHICH REPEATS FOREVER.
1420 IN BRIEF, THE RULES SHOULD BE SUCH
1430 AS TO MAKE THE BEHAVIOUR OF THE
1440 POPULATIOB UNPREDICTABLE.
1450 * *
1460 THE RULES WHICH RESULT FROM THESE
1470 DESIDERATA ARE VERY SIMPLE. FIRST
1480 NOTE THAT ANY SQUARE IN A CHECKER-
1490 BOARD (ASSUMING ONE THAT IS INFIN-
1500 ITE IN BOTH DIRECTIONS) HAS EIGHT
1510 OTHER SQUARES AROUND IT, OR EIGHT
1520 NEIGHBOURS. THE RULES ARE:
1530 SURVIVALS: EVERY CELL WITH 2 OR 3
1540 . NEIGHBOURS SURVIVES TO THE NEXT
1550 . GENERATION.
1560 DEATHS: EACH CELL WITH 4 OR MORE
1570 . NEIGHBOURS DIES FROM OVERCROWD-
1580 . ING. EACH CELL WITH 1 OR LESS
1590 . NEIGHBOURS DIES FROM ISOLATION.
1600 BIRTHS: ANY EMPTY LOCATION WHICH
1610 . HAS EXACTLY 3 NEIGHBOURING LOC-
1620 . ATIONS CONTAINING CELLS WILL
1630 . HAVE A CELL IN IT IN THE NEXT
1640 . GENERATION.
1650 * *
1660 IT'S IMPORTANT TO NOTE THAT BIRTHS
1670 AND DEATHS OCCUR SIMULTANEOUSLY IN
1680 THE DEVELOPMENT OF THE NEXT GENER-
1690 ATION. ORIGINALLY, THIS PROCESS
1700 WAS DONE USING 2 COLOURS OF CHECK-
1710 ERS ON A CHECKERBOARD. NOW, DUE
1720 TO THE MARVEL OF THE COMMODORE 64,
1730 WE CAN PERFORM A TEDIOUS JOB IN A
1740 FEW SECONDS WITHOUT MAKING ANY
1750 ERRORS AT ALL.
1760 * *
1770 THE HISTORY OF MANY OF THE SIMPLE
1780 INITIAL PATTERNS OR COLONIES HAVE
1790 BEEN CHARTED AND ARE SHOWN BELOW.
1800 AS WELL, SOME OF THE MORE COMMON
1810 STABLE PATTERNS ARE ALSO SHOWN.
1820 * *
1830 *********THE 5 TRIPLETS***********
1840 * *
1850 * GEN #0 GEN#1 GEN#2 *
1860 ----------------------------------
1870 " [209]
1880 " (null) (null)(null) DIES
1890 " [209]
1900 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
1910 " (null) (null) DIES
1920 " [209] [209] [209]
1930 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
1940 " (null)
1950 " [209] [209] DIES
1960 " (null)
1970 ----------------------------------
1980 " [209][209] [209][209] THE BLOCK
1990 " (null) (null)(null) (STABLE)
2000 ----------------------------------
2010 " [209]
2020 " (null)(null)(null) (null) BLINKER
2030 " [209] (CYLCLE=2
2040 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
2050 [172] [172]
2060 [172][172][172][172][172][172]THE FIVE TETROMINOES[172][172][172][172][172][172][172][172]
2070 [172] [172]
2080 [172] GEN #0 GEN#1 GEN#2 [172]
2090 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
2100 " (null)(null) (null)(null) THE BLOCK
2110 " [209][209] [209][209] (STABLE)
2120 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
2130 " (null)(null) (null)(null)
2140 " [209][209][209][209] [209][209] [209] [209]
2150 " (null)(null) (null)(null)
2160 " BEEHIVE (STABLE)
2170 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
2180 " (null) (null)(null) (null)(null)
2190 " [209][209] [209][209] [209] [209]
2200 " (null) (null)(null) (null)(null)
2210 " BEEHIVE (STABLE)
2220 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
2230 " (null) (null) (null)(null)
2240 " [209][209][209] [209][209] [209][209]
2250 " (null) (null)(null)
2260 " SAME AS ABOVE
2270 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
2280 " (null) (null)(null)(null) (null)
2290 " [209][209][209] [209][209][209] [209] [209]
2300 " (null)
2310 " [209][209][209]
2320 " CONTINUES TO A
2330 " PATTERN CALLED
2340 " STREETLIGHTS.
2350 ----------------------------------
2360 * *
2370 *********STABLE FORMS*************
2380 * *
2390 ----------------------------------
2400 " [209] [209][209] [209][209]
2410 " (null) (null) (null) (null) (null) (null)
2420 " [209] [209] [209] [209] [209] [209]
2430 " (null) (null) (null)(null)
2440 " BEEHIVE LOAF POND
2450 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
2460 " (null) (null)(null) (null)CLOSE(null)(null)
2470 " [209] [209] [209][209] [209][209] [209]
2480 " (null)
2490 " TUB BLOCK SNAKE
2500 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
2510 " (null) (null) (null)(null)
2520 " [209] [209] [209] [209] [209] [209]
2530 " (null) (null) (null)(null) (null)(null)
2540 " [209]
2550 " BARGE BOAT SHIP
2560 ----------------------------------
2570 " [209] [209] [209][209]
2580 " (null) (null) (null) (null) (null) (null)
2590 " [209] [209] [209] [209] [209] [209]
2600 " (null) (null) (null)(null) (null)(null)
2610 " [209]
2620 "LONG BARGE LONG BOAT LONG SHIP
2630 ----------------------------------
2640 * *
2650 *****INTERESTING PATTERNS*********
2655 * TRY STARTING WITH THESE *
2660 * *
2670 ----------------------------------
2680 " [209][209] [209] [209] [209]
2690 " (null)(null) (null)(null)(null) (null)(null)(null)
2700 " [209] [209] [209] [209]
2710 " (null)
2720 " THE 'R' LATIN LETTER
2730 "PENTOMINO CROSS 'H'
2740 ----------------------------------
2750 " [209] [209][209][209] [209][209] [209][209][209]
2760 " (null) (null) (null)(null) (null)CLOSE(null)
2770 " [209][209][209][209][209] [209][209] [209][160][209]
2780 " (null)CLOSE(null) (null)(null)
2790 " [209][209][209][160][209] SYMBOL
2800 " SWASTIKA BEACON '(null)'
2810 ----------------------------------
2820 " [209] [209]
2830 " (null)(null) (null)(null)(null) (null)
2840 " [209][209] [209][209][209] [209][209][209]
2850 " (null)
2860 " CLOCK TOAD GLIDER
2870 [171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171][171]
2880 [172] [172]
2890 THERE ARE MANY OTHER BEAUT[139]UL
2900 PATTERNS WHICH CAN BE GENERATED BY
2910 THIS SIMULATI[145]. TRY A FEW [162]
2920 STARTING PATTERNS [175] SEE HOW THEY
2930 GROW [175] DIE [171] SURPRI[191]G YOU ALL
2940 THE TIME.
2950 [172] [172]
2960 THE PROGRAM PROVIDED IS WRITTEN IN
2970 A COMBINATI[145] OF BASIC [175] MACHINE
2980 LANGUAGE. THE MACHINE LANGUAGE
2990 WAS USED [164] PROVIDE SPEED DURING
3000 THE CREATI[145] OF [162] GENERATI[145]S.
3010 THE PROGRAM WILL ALLOW YOU [164] [147]
3020 [175] [148] PATTERNS [145] THE DISK AT
3030 ANY TIME. [139] YOU FIND A PARTIC[171]
3040 ULARLY [181]ERESTING PATTERN, I
3050 WOULD BE PLEASED [164] HEAR FROM YOU
3060 AT THE FOLLOWING ADDRESS:
3070 " GLEN BODIE
3080 " 90 KINGSMOUNT PK RD
3090 " TORONTO, ONTARIO
3100 " M4L 3L4
3110 " (416) 461-3483
3120 AS A LAST NOTE, WHEN USING THE
3130 PROGRAM, YOU CAN ALWAYS PRESS F8
3140 IN ORDER TO SEE THE "HELP" INFOR-
3150 MATION. THIS GIVES YOU SOME GEN-
3160 ERAL INFO LIKE THAT ABOVE AND A
3170 DESCRIPTION OF THE PURPOSES OF THE
3180 FUNCTION KEYS.
3190 * *
3200 ENJOY YOUR "LIFE"!